<ion-header>

  <ion-navbar>
    <ion-title>{{ 'SIGNUP_TITLE' | translate }}</ion-title>
  </ion-navbar>

</ion-header>

<ion-content>
    <ion-list>
      <ion-item>
        <ion-label fixed>{{ 'USERNAME' | translate }}</ion-label>
        <ion-input type="text" placeholder="{{ 'USERNAME' | translate }}" [(ngModel)]="user.accountName" name="accountName"></ion-input>
      </ion-item>

      <ion-item>
        <ion-label fixed>{{ 'EMAIL' | translate }}</ion-label>
        <ion-input type="email" placeholder="{{ 'EMAIL' | translate }}" [(ngModel)]="user.qq" name="qq"></ion-input>
      </ion-item>

      <ion-item>
        <ion-label fixed>验证码</ion-label>
        <ion-input type="text" placeholder="请输入验证码" [(ngModel)]="user.code" name="code"></ion-input>
        <button item-right ion-button color="primary" (click)="getCode()" [disabled]="status">{{codeValue}}</button>
      </ion-item>

      <ion-item>
        <ion-label fixed>{{ 'MOBILE' | translate }}</ion-label>
        <ion-input type="text" placeholder="{{ 'MOBILE' | translate }}" [(ngModel)]="user.mobile" name="mobile"></ion-input>
      </ion-item>

      <ion-item>
        <ion-label fixed>{{ 'PASSWORD' | translate }}</ion-label>
        <ion-input type="password" placeholder="{{ 'PASSWORD' | translate }}" [(ngModel)]="user.password" name="password"></ion-input>
      </ion-item>

      <div padding>
        <button ion-button color="primary" [disabled]="!canSignUp()" block (click)="doSignup()">{{ 'SIGNUP_BUTTON' | translate }}</button>
      </div>

    </ion-list>
</ion-content>
